<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@page session="true"%>
<%@page import="com.webapp.model.User"%>
<%@page import="com.webapp.model.Application,java.util.Vector;" %>
<%
	User user = (User) session.getAttribute("UserObject");
	if (user != null)
		System.out.println(user.getUserName());
	Application app = (Application) session.getAttribute("Application");
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>GARS-Applicant's OTS Application</title>
<link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'>
<style type="text/css">
			body { font-size: 95%; font-family: 'Open Sans'; padding:0; margin:0; background-color:#fff;}
			h1 { padding:0; margin:0; }
			h2 { padding:0; margin:0; }
			.sign_on_btn { background-color: #CC0000; color: #fff; border: 1px solid #990000; padding: 5px; cursor:pointer!important;}
			.sign_on_btn:hover { background-color:red; }
			.txtbox { background-color:#fff; border: 1px solid #ccc; width: 30px; }<br />
			.txtbox:focus { border: 1px soild #CC0000; }
			a { color: blue; }
			#top_of_site { padding: 5px;color: #333; background-color: #333; color:#fff; border: 1px solid #000;}
			#top_of_site h1 { padding:0; margin:0; font-size: 90%; }
			#wrapper { padding: 15px; }
			#login { width: 300px; margin: 0px auto 0px auto; padding: 10px;background-color: #333; color:#fff; border: 1px solid #000; }
			#info_bar { text-align:right; }
			#menu_container { width: 560px; margin: 30px auto 0px auto;  overflow:auto;}
			#behaviorcontainer { float:left; width: 400px; overflow:auto; }
			#extra_info { width: 560px; margin: 30px auto 0px auto;}
			#menu_container a { text-decoration: none; color: #fff; }
			#logout { float:left; background-color:#f2f2f2; border: 1px solid #ccc; color:#333; width: 100px; padding: 59px 15px 59px 15px; margin: 5px; }
			#viewTable { background-color:#0066CC; border: 1px solid #0066FF; width: 350px; padding: 20px; margin: 5px; }
			#submitApp { background-color:#B22222; border: 1px solid #990000; width: 350px; padding: 20px; margin: 5px; } 
			#apptable td { padding: 5px; }
			.even { background-color:#fff; padding:10px; cursor:pointer!important; }
			.odd { background-color:#ccc; padding:10px;cursor:pointer!important; }
			.even:hover { background-color: #0066CC; color: #fff; cursor:pointer!important; }
			.odd:hover { background-color: #0066CC; color:#fff;cursor:pointer!important;  }
			
			.form { font-size: 15px; margin-left:auto; margin-right:auto; width:5%; background-color:#b0e0e6;}
			.okay_button{font-size: 20px; margin-left:auto; margin-right:auto; width:10%; background-color:#b0e0e6;}
			.btn { background-color: #CC0000; color: #fff; border: 1px solid #990000; padding: 5px; cursor:pointer!important;}
			.btn:hover { background-color:red; }
</style>
</head>
<body>
<body>
	<body>
	<div id="top_of_site">
		<h1>Graduate Application Review System (GARS)</h1>
	</div>
	
	<div id="wrapper">
	<form name="return" action="viewSingleAppsTest.jsp" method="get">
					<!-- Returns to the previous page, which would be the view table page.-->
					<input type="submit" value="Finished Viewing" class="btn">
				</form>
		<div id="info_bar">
			<p style="padding:0; margin:0;">Welcome, <strong><%= user.getUserName() %></strong>! You are a <strong><%= user.getType()  %></strong> member! </p>
            <p> You have <strong><%= user.getReviews()%></strong> reviews waiting to be reviewed! <br/><a href="ViewUserApp.do">Review Now!</a></p>
		</div>

		<div id="content">
			<h1>Applicant's OTS File</h1>
			<h3>(Last Updated: <%=app.getUploadDate()%>)</h3>
				<!-- Represents general information about the applicant in OTS file -->
			<div id="ots_general_info">
				<hr>
				<h3>
					<u>Applicant's General Information</u>
				</h3>
				<table border="0" width="1100" cellpadding="3" cellspacing="3">
					<tr>
						<td><b>E-Mail:</b> <i><%=app.getEmail()%></i>
					</tr>	
					
					<tr>
						<td><b>First Name:</b> <i><%=app.getFirstName()%></i>
						</td>

						<td><b>Last Name:</b> <i><%=app.getLastName()%></i>
						
						<td><b>Middle Name:</b> <i><%=app.getMiddleName()%></i>
					</tr>

					<tr>
						<td><b>Birth Date:</b> <i><%=app.getBirthDay() + "/" + app.getBirthMonth() + "/" + app.getBirthDay()%></i></td>

						<td><b>Sex:</b> <i><%=app.getGender()%></i></td>

						<td><b>Citizenship:</b> <i><%=app.getCitizenship()%></i>
						
						<td><b>Permanent Resident:</b> <i><%=app.getpPermanentResident()%></i></td>
					</tr>
				</table>
			</div>

			<div id="test_scores">
				<hr>
				<h3>
					<u>Applicant's Test Scores (GRE/TOELF)</u>
				</h3>
				<h4>GRE Scores:</h4>

				<table border="0" width=800 " cellpadding="3" cellspacing="3">
					<tr>
						<td><b>GRE Verbal Score:</b> <i><%=app.getOfclGreV()%></i></td>

						<td><b>GRE Verbal Percentile:</b> <i><%=app.getOfclGreVPctile()%></i></td>
					</tr>

					<tr>
						<td><b>GRE Quantitative Score:</b> <i><%=app.getOfclGreQ()%></i></td>

						<td><b>GRE Quantitative Percentile:</b> <i><%=app.getOfclGreQPctile()%></i></td>
					</tr>

					<tr>
						<td><b>GRE Analytical Score:</b> <i><%=app.getOfclGreA()%></i></td>

						<td><b>GRE Analytical Percentile:</b> <i><%=app.getOfclGreAPctile()%></i></td>
					</tr>

					<tr>
						<td><b>GRE Subject Score:</b> <i><%=app.getOfclGreSubj()%></i></td>

						<td><b>GRE Subject Percentile:</b> <i><%=app.getOfclGreSubjPctile()%></i></td>
						
						<td><b>GRE Subject Name:</b> <i><%=app.getOfclGreSubjName()%></i></td>
					</tr>
				</table>

				<h4>TOELF Scores:</h4>

				<table border="0" width=600 " cellpadding="3" cellspacing="3">
					<tr>
						<td><b>TOELF Total Score:</b> <i><%=app.getOfclToeflTotal()%></i></td>
					</tr>
					
					<tr>
						<td><b>TOELF Total Listening Score:</b> <i><%=app.getOfclToeflListen()%></i></td>

						<td><b>TOELF Total Reading Score:</b> <i><%=app.getOfclToeflRead()%></i></td>
					</tr>
					
					<tr>
						<td><b>TOELF Total Speaking Score:</b> <i><%=app.getOfclToeflSpeak()%></i></td>
						
						<td><b>TOELF Total Writing Score:</b> <i><%=app.getOfclToeflWrite()%></i></td>
					</tr>
				</table>
			</div>
			<div id="bottom_buttons">
				<br>
				<hr>
				<center>
					<form name="return" action="viewSingleAppsTest.jsp" method="get">
						<!-- Returns to the previous page, which would be the view table page.-->
						<input type="submit" value="Finished Viewing" class="btn">
					</form>
				</center>
			</div>
		</div>	
	</div>
</body>
</html>